package com.iot.enums;

public enum ResultEnum {
    SECCESS(0, "操作成功"),
    FAILURE(-1, "操作失败"),
    FORBIDDEN(-2, "权限不足"),
    INPUT_PARAM_ERROR(10001, "缺少参数"),
    AUTH_FAILURE(10002, "当前登录账号无权限"),
    AUTH_INFO_FAILURE(10003, "获取用户信息异常"),
    AUTH_LOGIN_FAILURE(10004, "账号/密码错误"),

    REQUEST_TIMEOUT(10005, "请求超时"),

    FIND_FAILURE(10006, "查询数据异常"),

    SIGN_PARAM_MISS(1001001, "鉴权参数缺少"),
    SIGN_PARAM_TIMEOUT(1001002, "鉴权参数超时，请检查系统时间"),
    SIGN_PARAM_FAILURE(1001003, "签名校验失败，请检查签名"),
    SIGN_TOKEN_MISS(1001501, "Token参数缺少"),
    SIGN_TOKEN_FAILURE(1001502, "Token校验失败，请重新登陆"),
    CHECK_TOKEN_INVALID(1001503, "Token校验无效，请重新登陆");
    private Integer code;
    private String message;

    private ResultEnum(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    public Integer getCode() {
        return this.code;
    }

    public String getMessage() {
        return this.message;
    }
}
